package com.xpertline.ui.invoice;

import java.awt.BorderLayout;
import java.awt.Dimension;
import java.awt.FlowLayout;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.JButton;
import javax.swing.JDialog;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JTable;
import javax.swing.table.DefaultTableModel;

public class ListRoomInvoicePane extends JPanel {
	private JTable table;

	/**
	 * Create the panel.
	 */
	public ListRoomInvoicePane() {
		setLayout(new BorderLayout(0, 0));
		
		JPanel panel = new JPanel();
		FlowLayout flowLayout = (FlowLayout) panel.getLayout();
		flowLayout.setAlignment(FlowLayout.LEFT);
		add(panel, BorderLayout.NORTH);
		
		JButton btnHinTtC = new JButton("Hi\u1EC7n t\u1EA5t c\u1EA3");
		btnHinTtC.setPreferredSize(new Dimension(100, 25));
		panel.add(btnHinTtC);
		
		JButton btnHinMtPhn = new JButton("Hi\u1EC7n m\u1ED9t ph\u1EA7n");
		panel.add(btnHinMtPhn);
		
		JButton btnXa = new JButton("X\u00F3a");
		btnXa.setPreferredSize(new Dimension(100, 25));
		panel.add(btnXa);
		
		JScrollPane scrollPane = new JScrollPane();
		add(scrollPane, BorderLayout.CENTER);
		
		table = new JTable();
		table.setRowHeight(20);
		table.setModel(new DefaultTableModel(
			new Object[][] {
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
				{null, null, null, null, null, null, null, null, null},
			},
			new String[] {
				"Ng\u00E0y", "S\u1ED1 ph\u00F2ng", "T\u00ECnh tr\u1EA1ng", "M\u00E3 h\u1ED9i vi\u00EAn", "T\u00EAn h\u1ED9i vi\u00EAn", "B\u1EAFt \u0111\u1EA7u", "K\u1EBFt th\u00FAc", "Th\u1EDDi l\u01B0\u1EE3ng", "T\u1ED5ng ph\u1EA3i thu"
			}
		) {
			Class[] columnTypes = new Class[] {
				String.class, String.class, Object.class, Object.class, Object.class, Object.class, Object.class, Object.class, Object.class
			};
			public Class getColumnClass(int columnIndex) {
				return columnTypes[columnIndex];
			}
		});
		table.getColumnModel().getColumn(0).setPreferredWidth(82);
		table.getColumnModel().getColumn(1).setPreferredWidth(62);
		table.getColumnModel().getColumn(2).setPreferredWidth(58);
		table.getColumnModel().getColumn(3).setPreferredWidth(64);
		table.getColumnModel().getColumn(4).setPreferredWidth(89);
		table.getColumnModel().getColumn(5).setPreferredWidth(60);
		table.getColumnModel().getColumn(6).setPreferredWidth(56);
		table.getColumnModel().getColumn(8).setPreferredWidth(77);
		table.setFillsViewportHeight(true);
		scrollPane.setViewportView(table);

	}

}
